package com.uls.hdh.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.uls.hdh.mapper.HdhOptionsMapper;
import com.uls.hdh.domain.HdhOptions;
import com.uls.hdh.service.IHdhOptionsService;

/**
 * 选项Service业务层处理
 * 
 * @author hdh
 * @date 2024-11-09
 */
@Service
public class HdhOptionsServiceImpl implements IHdhOptionsService 
{
    @Autowired
    private HdhOptionsMapper hdhOptionsMapper;

    /**
     * 查询选项
     * 
     * @param optionId 选项主键
     * @return 选项
     */
    @Override
    public HdhOptions selectHdhOptionsByOptionId(Long optionId)
    {
        return hdhOptionsMapper.selectHdhOptionsByOptionId(optionId);
    }

    /**
     * 查询选项列表
     * 
     * @param hdhOptions 选项
     * @return 选项
     */
    @Override
    public List<HdhOptions> selectHdhOptionsList(HdhOptions hdhOptions)
    {
        return hdhOptionsMapper.selectHdhOptionsList(hdhOptions);
    }

    /**
     * 新增选项
     * 
     * @param hdhOptions 选项
     * @return 结果
     */
    @Override
    public int insertHdhOptions(HdhOptions hdhOptions)
    {
        return hdhOptionsMapper.insertHdhOptions(hdhOptions);
    }

    /**
     * 修改选项
     * 
     * @param hdhOptions 选项
     * @return 结果
     */
    @Override
    public int updateHdhOptions(HdhOptions hdhOptions)
    {
        return hdhOptionsMapper.updateHdhOptions(hdhOptions);
    }

    /**
     * 批量删除选项
     * 
     * @param optionIds 需要删除的选项主键
     * @return 结果
     */
    @Override
    public int deleteHdhOptionsByOptionIds(Long[] optionIds)
    {
        return hdhOptionsMapper.deleteHdhOptionsByOptionIds(optionIds);
    }

    /**
     * 删除选项信息
     * 
     * @param optionId 选项主键
     * @return 结果
     */
    @Override
    public int deleteHdhOptionsByOptionId(Long optionId)
    {
        return hdhOptionsMapper.deleteHdhOptionsByOptionId(optionId);
    }
}
